import React from 'react'
import { Table, Icon } from 'antd';
import createContainer from '../../utils/createContainer';
const columns = [{
    title: '标题',
    dataIndex: 'title',
    key: 'title',
    }, {
    title: '内容',
    dataIndex: 'content',
    key: 'content',
    }, {
    title: '操作',
    key: 'action',
    render: (text, record) => (
        <span>
        <a href="#">修改</a>
        <span className="ant-divider" />
        <a href="#">删除</a>
        </span>
    ),
}];
const List = (props) => (
	<div>
                <div className="plant">
                    <h3>计划表</h3>
                    <p>添加计划</p>
                </div>
                <Table rowKey = "id" columns={columns} dataSource={props.planData} />
            </div>
)

const ListContainer = createContainer(
    ({planData}) => ({planData}), // mapStateToProps,
    require('../../redux/actions/plan').default, // mapActionCreators,
    List // 木偶组件
)


export default ListContainer;